#ifndef ROOM_H
#define ROOM_H

#include "autoload.h"
#include "user.h"

class Room
{
public:
    Room(){}
    Room(QString name, bool passNeed);
    QString getName();
    bool getNeed();
    QList<User*> getUsers()
    {
        return users;
    }

    void setUsers(QList<User*> u)
    {
        users = u;
    }
    void setMsgs(QList<QString>* rule)
    {
        this->messages = messages;
    }
    QString getMsg(int i)
    {
        return messages[i];
    }
    void addMsg(QString msg)
    {
        messages.append(msg);
    }
    int msgsCount()
    {
        return messages.size();
    }
    void cleanMessages()
    {
        messages.clear();
    }

private:
    QString name;
    bool passNeed;
    QList<User*> users;
    QList<QString> messages;
};

#endif // ROOM_H
